package com.example.chcrm.entity.vehicle;

import com.baomidou.mybatisplus.annotation.*;
import com.example.chcrm.entity.common.OperateRecord;
import com.example.chcrm.entity.supplier.HighwaySupplierCar;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;

import java.io.Serializable;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * @Author 邹
 * @Date 2025/4/26 14:44
 * @Version 1.0
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class VehicleDeployFleetCv implements Serializable {
    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.INPUT)
    private String id;
    private String fleetId;     //公路供应商id
    private String fleetName;   //供应商名称

    @Excel(name = "司机姓名",width = 30,orderNum = "3")
    private String driverName;      //司机姓名
    @Excel(name = "联系电话",width = 30,orderNum = "4")
    private String driverTel;       //司机联系电话
    private String truckId;         //运输车id
    @Excel(name = "车牌号",width = 30,orderNum = "2")
    private String truckName;       //运输车车牌号

    private String taskCode;    //任务编号
    private Integer fleetCount;     //预计装车数量
    private Integer surplusCount;   //实际装车数量
    private Integer surdownCount;   //实际卸船数量
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date fulfilTime;    //完成时间
    //装车
    private Integer startType;  //起始类型 0：区域 1：港口
    private String startId;     //起始地id
    private String startFullId; //起始地id(包含父级id)
    private String startName;   //起始地区域名称
    private String startCoordinate; //起始地坐标位置
    private String startPortId;     //起始港id
    private String startPortName;   //起始港名
    //交车
    private Integer deliveryType;       //交车类型 0：区域 1：港口
    private String deliveryId;          //交车位置id
    private String deliveryFullId;      //交车位置id(包含父级id)
    private String deliveryName;        //交车位置区域名称
    private String deliveryCoordinate;  //交车位置坐标
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String deliveryPortId;      //交车港id
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String deliveryPortName;    //交车港名

    private String remark;      //备注
    private Integer status;     //状态 0：待开始 1：执行中 2：已完成
    private Integer isupaddr;   //是否修改交车地0：未修改、1：修改
    private String upaddRemarks;//修改备注交车地
    private Integer resource;//0需要验证交车区域 1不需要验证通过计划生成

    @TableField(fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;    //创建时间
    @TableLogic(value = "0", delval = "-1")
    private Integer isDeleted;  //是否删除

    @TableField(exist = false)
    private Integer page = 1;
    @TableField(exist = false)
    private Integer rows = 10;
    @TableField(exist = false)
    private List<OperateRecord> operateRecordList;  //操作记录
    @TableField(exist = false)
    private List<Map<String, Object>> childList;
    @TableField(exist = false)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private String startTime;   //装车时间
    @TableField(exist = false)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private String endTime;     //交车时间

    @TableField(exist = false)
    private List<HighwaySupplierCar> carDocList;    //运输车
    @TableField(exist = false)
    private List<VehicleDeployCarCv> carList;       //调配委托车
    @TableField(exist = false)
    private List<String> carIds;
    //    @TableField(exist = false)
//    private List<VehicleDeployDriverCv> driverList; //调配司机
    @TableField(exist = false)
    private String deliveryPlace;//卸车地地址
}
